/**
 * This file needs to be loaded before the other files
 * due to namespace setup
 */

// setting up the game's name space.
pepperstad = {};

// Setting window.self to undefined. Purely a safety measure to make sure the program will crash reliably when
// using a variable named self which erroneously has not been defined in the enclosing function (eg var self = this;)
// in stead of continuing with side effects where self is actually the window object.
window.self = undefined;

$(function () {

    if (typeof editMode != "undefined" && editMode) {
        new pepperstad.Editor().init();
    }
    else {
        new pepperstad.Game().init();
    }
    $(document).tooltip();
});
